package com.itheima.chapter06.innerclass.test2;

public class Test1 {
    public static void main(String[] args) {
        /*
        成员内部类：私有内部类
         */


       /* Outer.Inner oi = new Outer().new Inner();             private class Inner
        oi.show();*/
       Outer o =new Outer();
       o.method();

    }
}

class Outer{
    private  int a=55;
    private class Inner{
        int num =10;
        public void show(){
            System.out.println("Inner...show");
            System.out.println(a);      //内部类可以直接访问外部类成员，包括私有
        }
    }
    public void method(){
        Inner i =new Inner();
        i.show();
    }
}